/*
 * Copyright (c) 2022  by Junzhao
 * THIS FILE IS PART OF JAVASE Song Huongkang PROJECT
 * All Rights Reserved.
 */

package 动态代理.回顾静态代理;

/**
 * @Description 静态代理举例
 * 编译期间 代理类和被代理类 就已经确定
 * @Author 俊昭
 * @Date 2022/5/11
 */
public class StaticProxyTest {
    public static void main(String[] args) {
        //实例化被代理工厂
        JZClothFactory factory = new JZClothFactory();


        //实例化代理工厂
        ProxyClothFactory proxyClothFactory = new ProxyClothFactory(factory);

        //进行生产
        proxyClothFactory.produceCloth();

        //代理工厂准备
        //被代理工厂生产衣服
        //代理工厂做后续的事
    }
}

